<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>操作评价</title>
</head>
<body style="background: #ffffff;">
	<input type="hidden" id="uuid" value="${uuid}">
	<input type="hidden" id="max" value="${max}">
	<form id="myForm" action="layUITextarea/save" method="post"
		class="layui-form layui-form-pane">
		<table class="layui-table" id="tablee">
			<colgroup>
				<col width="150">
				<col>
				<col width="200">
				<col width="200">
			</colgroup>
			<thead>
				<tr>
					<th style="text-align: center;">评分指标</th>
					<th style="text-align: center;">评价标准描述</th>
					<th style="text-align: center;">权重</th>
					<th style="text-align: center;">打分</th>
				</tr>
			</thead>

			<tbody>
				<c:forEach items="${page}" var="c">
					<input type="hidden" id="readonly${c.sum }" value="${c.grade}">
					<tr>
						<td align="center">${c.system}<span></span></td>
						<td><span></span>${c.explain}</td>
						<td align="center">${c.weight }<span></span></td>
						<td align="center"><span id="rateevaluation${c.sum }"></span></td>
					</tr>
				</c:forEach>
			</tbody>
		</table>
		
		<div class="layui-form-item layui-form-text" style="width: 98%;margin:1%">
		    <label class="layui-form-label" style="color: #666666">教师点评</label>
		    <div class="layui-input-block">
		      <textarea placeholder="请输入内容" class="layui-textarea" readonly="readonly">${evaluation }</textarea>
		    </div>
		  </div>
		  <div class="layui-form-item layui-form-text" style="width: 98%;margin:1%">
		    <label class="layui-form-label" style="color: #666666">建议</label>
		    <div class="layui-input-block">
		      <textarea placeholder="请输入内容" class="layui-textarea" name="suggest" readonly="readonly">${suggest }</textarea>
		    </div>
		  </div>
	</form>
	<script type="text/html" id="barDemoopen">
		<div class="aaa"></div>
	</script>
	<script>
$(function(){
	var indexs = 0;
			
			layui.use([ 'rate' ], function() {
				var rate = layui.rate;
				var max = $("#max").val();
				/* 没有点击事件 */
				for (var i = 0; i < max; i++) {
					var readonlynumber= $("#readonly"+i).val();
					rate.render({
						elem : '#rateevaluation' + i,
						value : readonlynumber,
						text : true,
						theme : '#ff8000',
						readonly :'true'
					});
				}
				
			});

		});
	</script>
</body>
</html>